package com.newegg.whois.plugin;

import java.util.Map;

public class FixCreationDatePlugin{
	
	static String key = "creationDate";
	static String[] fixKeyList = new String[]{"created"};

	public static Map<String, Object> fix(Map<String, Object> data) {
		for (String fixKey : fixKeyList) {
			if(data.containsKey(fixKey)){
				Object value = data.get(fixKey);
				if(value != null && !"".equals(value.toString())){
					data.put(key, data.get(fixKey));
				}
			}
		}
		return data;
	}
}
